<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
$err="";
include 'sub/loginFuncs.php'; 
include 'sub/pageMode.php';

$txtUser = isset($_POST['txtUser']) ? Str::s2n(($_POST['txtUser'])) : "";
$txtPass = isset($_POST['txtPass']) ? Str::s2n(($_POST['txtPass'])) : "";
$txtPass=md5($txtPass);
if(Http::isPost()){
    $uinfo=getUserInfo($txtUser, $txtPass);
    if($uinfo) {
        setSession($uinfo);
    }
    else
        {
            $err ='User Name or Password is wrong!';
        }
}
?>
